Style transfer

ABSTRACT

Various implementations of the present disclosure relate to style transfer. In some implementations, a computer-implemented method comprises: obtaining a target object having a first style, a style of the target object being editable; obtaining a reference image including a reference object; obtaining a second style of the reference object, the second style of the reference object being extracted from the reference image; and applying the second style to the target object.

CROSS-REFERENCE TO RELATED APPLICATION

This application is a U.S. National Stage Filing under 35 U.S.C. 371 ofInternational Patent Application Serial No. PCT/US2020/016309, filedFeb. 3, 2020, and published as WO 2020/180437 A1 on Sep. 10, 2020, whichclaims priority to Chinese Application No. 201910161417.9, filed Mar. 4,2019, which applications and publication are incorporated herein byreference in their entirety.

BACKGROUND

Editable objects like charts and tables have an important role in dailylife. However, while using these editable objects, users often feelconfused or difficult to decide what kind of design or style (e.g.,color and layout etc.) should be used. In addition, even if users knowthe design or style to be used, they cannot quickly apply such style.Instead, users need to adjust the respective elements in the editableobjects according to each style element and time cost of such operationis quite high.

SUMMARY

Various implementations of the present disclosure provide a styletransfer solution for the editable objects (e.g., charts, tables and thelike). In some implementations, a target object having a first style maybe obtained, the style of the target object being editable. A referenceimage comprising a reference object may be obtained. A second style ofthe reference object may be obtained, the second style of the referenceobject being extracted from the reference image. The second style may beapplied to the target object.

This Summary is provided to introduce a selection of concepts in asimplified form that are further described below in the DetailedDescription. This Summary is not intended to identify key features oressential features of the subject matter, nor is it intended to be usedto limit the scope of the subject matter.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a block diagram illustrating a computing device forimplementing various implementations of the present disclosure;

FIG. 2 illustrates a schematic diagram of architecture for styletransfer in accordance with some implementations of the presentdisclosure;

FIG. 3 illustrates a schematic diagram of a model for style transfer inaccordance with some implementations of the present disclosure;

FIG. 4 illustrates a schematic diagram of a decoder in accordance withsome implementations of the present disclosure;

FIG. 5 illustrates a flowchart of a method for style transfer inaccordance with some implementations of the present disclosure;

FIG. 6 illustrates a flowchart of another method for style transfer inaccordance with some implementations of the present disclosure.

In these drawings, same or similar reference signs indicate same orsimilar elements.

DETAILED DESCRIPTION OF EMBODIMENTS

The present disclosure will now be discussed with reference to severalexample implementations. It is to be understood these implementationsare discussed only for the purpose of enabling those skilled persons inthe art to better understand and thus implement the present disclosure,rather than suggesting any limitations on the scope of the subjectmatter.

As used herein, the term “includes” and its variants are to be read asopen terms that mean “includes, but is not limited to.” The term “basedon” is to be read as “based at least in part on.” The term “oneimplementation” and “an implementation” are to be read as “at least oneimplementation.” The term “another implementation” is to be read as “atleast one other implementation.” The terms “first,” “second,” and thelike may refer to different or same objects. Other definitions, explicitand implicit, may be included below.

Basic principles and several example implementations of the presentdisclosure are explained below with reference to the drawings. FIG. 1illustrates a block diagram of a computing device 100 that can carry outa plurality of implementations of the present disclosure. It should beunderstood that the computing device 100 shown in FIG. 1 is onlyexemplary and shall not constitute any restrictions over functions andscopes of the implementations described by the present disclosure.According to FIG. 1 , the computing device 100 includes a computingdevice 100 in the form of a general purpose computing device. Componentsof the computing device 100 can include, but not limited to, one or moreprocessors or processing units 110, memory 120, storage device 130, oneor more communication units 140, one or more input devices 150 and oneor more output devices 160.

In some implementations, the computing device 100 can be implemented asvarious user terminals or service terminals with computing power. Theservice terminals can be servers, large-scale computing devices and thelike provided by a variety of service providers. The user terminal, forexample, is mobile terminal, fixed terminal or portable terminal of anytypes, including mobile phone, site, unit, device, multimedia computer,multimedia tablet, Internet nodes, communicator, desktop computer,laptop computer, notebook computer, netbook computer, tablet computer,Personal Communication System (PCS) device, personal navigation device,Personal Digital Assistant (PDA), audio/video player, digitalcamera/video, positioning device, television receiver, radio broadcastreceiver, electronic book device, gaming device or any othercombinations thereof consisting of accessories and peripherals of thesedevices or any other combinations thereof. It can also be predicted thatthe computing device 100 can support any types of user-specificinterfaces (such as “wearable” circuit and the like).

The processing unit 110 can be a physical or virtual processor and canexecute various processing based on the programs stored in the memory120. In a multi-processor system, a plurality of processing unitsexecutes computer-executable instructions in parallel to enhanceparallel processing capability of the computing device 100. Theprocessing unit 110 also can be known as central processing unit (CPU),microprocessor, controller and microcontroller.

The computing device 100 usually includes a plurality of computerstorage media. Such media can be any attainable media accessible by thecomputing device 100, including but not limited to volatile andnon-volatile media, removable and non-removable media. The memory 120can be a volatile memory (e.g., register, cache, Random Access Memory(RAM)), a non-volatile memory (such as, Read-Only Memory (ROM),Electrically Erasable Programmable Read-Only Memory (EEPROM), flash), orany combinations thereof. The memory 120 can include a format painter122 configured to execute functions of various implementations describedherein. The format painter 122 can be accessed and operated by theprocessing unit 110 to perform corresponding functions.

The storage device 130 can be removable or non-removable medium, and caninclude machine readable medium, which can be used for storinginformation and/or data and can be accessed within the computing device100. The computing device 100 can further include a furtherremovable/non-removable, volatile/non-volatile storage medium. Althoughnot shown in FIG. 1 , there can be provided a disk drive for readingfrom or writing into a removable and non-volatile disk and an opticaldisk drive for reading from or writing into a removable and non-volatileoptical disk. In such cases, each drive can be connected via one or moredata medium interfaces to the bus (not shown).

The communication unit 140 implements communication with anothercomputing device through communication media. Additionally, functions ofcomponents of the computing device 100 can be realized by a singlecomputing cluster or a plurality of computing machines, and thesecomputing machines can communicate through communication connections.Therefore, the computing device 100 can be operated in a networkedenvironment using a logic connection to one or more other servers, aPersonal Computer (PC) or a further general network node.

The input device 150 can be one or more various input devices, such asmouse, keyboard, trackball, voice-input device and the like. The outputdevice 160 can be one or more output devices, e.g., display, loudspeakerand printer etc. The computing device 100 also can communicate throughthe communication unit 140 with one or more external devices (not shown)as required, wherein the external device, e.g., storage device, displaydevice etc., communicates with one or more devices that enable the usersto interact with the computing device 100, or with any devices (such asnetwork card, modem and the like) that enable the computing device 100to communicate with one or more other computing devices. Suchcommunication can be executed via Input/Output (I/O) interface (notshown).

In some implementations, apart from being integrated on an individualdevice, some or all of the respective components of the computing device100 also can be set in the form of cloud computing architecture. In thecloud computing architecture, these components can be remotely arrangedand can cooperate to implement the functions described by the presentdisclosure. In some implementations, the cloud computing providescomputation, software, data access and storage services withoutinforming a terminal user of physical positions or configurations ofsystems or hardware providing such services. In various implementations,the cloud computing provides services via Wide Area Network (such asInternet) using a suitable protocol. For example, the cloud computingprovider provides, via the Wide Area Network, the applications, whichcan be accessed through a web browser or any other computing components.Software or components of the cloud computing architecture andcorresponding data can be stored on a server at a remote position. Thecomputing resources in the cloud computing environment can be merged orspread at a remote datacenter. The cloud computing infrastructure canprovide, via a shared datacenter, the services even though they areshown as a single access point for the user. Therefore, components andfunctions described herein can be provided using the cloud computingarchitecture from a service provider at a remote position.Alternatively, components and functions also can be provided from aconventional server, or they can be mounted on a client device directlyor in other ways.

The computing device 100 can be used for implementing the style transfersolution according to implementations of the present disclosure. Here,editable objects refer to target objects with editable style, e.g.,charts or tables generated within presentation applications,text-processing applications and/or spreadsheet applications. Forexample, the style of the chart can include color, pattern, border,shading, coordinates and the like. Different from the general formatwhich reflects a single or a particular element of the appearance, the“style” of the editable object represents an overall appearance of theobject and is often embodied by different appearance elements. Forexample, the “style” of the editable object contains elements, such ascolor, pattern, border, shading and coordinates manifesting the overallappearance and/or layout of the object.

In some implementations, the editable objects also can be documentsgenerated by the presentation application, the text-processingapplication and/or the spreadsheet application. For example, as editableobjects, the style of these documents can embody font, size, linespacing, indentation, background and layout etc.

During the style transfer of the editable objects (e.g., charts ortables), the computing device 100 can receive, via the input device 150,a reference image 170, which can include a reference object, such as achart. A format painter 122 can process the reference image 170 andextract a style of the reference object in the reference image 170. Inaddition, the computing device 100 can receive, via the input device150, an editable object, which may be a chart or table. For example, theextracted style of the reference object can be applied to the editableobject to modify its style. The modified editable object can be providedto the output device 160 and then further to the user as an output 180.For example, the modified editable object can be shown on a display andpresented for the user.

Example implementations of the present disclosure will be described indetails below with reference to FIGS. 2-5 . FIG. 2 illustrates aschematic diagram of architecture 200 for style transfer in accordancewith some implementations of the present disclosure. A formant painter122 can be implemented at least partially by the architecture 200. Itshould be appreciated that FIG. 2 is provided for the purpose ofillustration only and is not intended to limit the scope of the presentdisclosure. One or more modules in the architecture 200 for styletransfer can be combined into a module, one or more modules can be addedinto the architecture 200 for style transfer, one or more modules of thearchitecture 200 for style transfer can be replaced and/or the like,without departing from the spirit and the scope of the presentdisclosure.

The user can import a reference image 202 from the local computingdevice or can obtain a reference image 202 from the network, forexample, providing a link of the reference image 202. The referenceimage 202 may not be editable and includes a reference object, such as achart. For the sake of convenience, the object will be described belowwith reference to charts. However, it should be understood that theprinciple of the present disclosure also can be applied to other objectslike tables.

The reference image 202 is style parsed to obtain a style of thereference object therein. For example, the style of the reference image202 can be parsed at the local computing device. Alternatively, thereference image 202 can be uploaded to a server (e.g., cloud), whichparses the style of the reference image 202 and then provides the parsedto the local device. After a style 206 of the reference object isobtained, the style 206 is applied to a chart 204 having a predefinedstyle. The chart 204 can be generated by a presentation application, atext-processing application and/or a spreadsheet application. The styleof the chart 204 is modified to or replaced by the style 206, so as toobtain an output chart 208 having the style 206.

In some implementations, the style parsing can be performed by apredefined rule. Taking a bar chart as an example, a color having thelargest area in the reference image 202 can be considered as abackground color and a color having the second largest area isconsidered as a color for a bar in the bar chart. Based on a rule-basedmodel, the style can be extracted at the cost of lower computingresources and the response time of the style transfer is reducedaccordingly, which will be favorable to the implementation of theoffline style transfer on limited computing resources.

In some implementations, the style parsing can be implemented by aneural network. For example, FIG. 3 illustrates a schematic diagram of aneural network model 300 for style transfer in accordance with someimplementations of the present disclosure. As shown in FIG. 3 , theneural network model 300 includes a style parsing portion 320 forparsing or extracting the style of the reference chart in the referenceimage and a style adapting portion 340 for applying the parsed orextracted style into the target chart. The style parsing portion 320 canbe trained based on a large-scale data set for extracting the style ofan image or an object.

In the style parsing portion 320, the reference image 302 is provided toan encoder 304 to convert the reference image 302 into a representationof the reference image 302, e.g., vector representation. For example,the encoder 304 can be implemented by a Convolutional Neural Network(CNN).

The style can include a plurality of style elements, like color,pattern, background, border, shading and display/non-display ofnumerical values etc. Therefore, a decoder can be used to decode acorresponding style element. As shown in FIG. 3 , the decoders 306-1 to306-N are used for decoding N different style elements respectively toobtain various style elements. For example, the decoder 306-1 can obtaina color-related style element, which outputs a color sequence. The styleelements outputted by decoders 306-1 to 306-N can be combined togetheras a parsed style, which is then outputted to the style adapting portion340.

In some implementations, an object detecting module (not shown) can beadded in the style parsing portion 320 to detect various parts (such asbackground, bar and the like) in the reference chart (e.g., bar chart).The output of the object detecting module can be provided to the decoderto better extract features of the reference chart. For example, a partcorresponding to the background in the feature vectors of the encoder304 can be provided to the decoder that extracts background-relatedinformation. In this way, related style elements of the reference chartcan be extracted more efficiently.

In some implementations, functions corresponding to some of the decoderscan be replaced by the rule-based model to boost the computingefficiency. For example, color may be one of the style elements with thehighest computing complexity for charts. Therefore, in order to boostthe computing efficiency, the style element of color can be implementedby the rule-based model.

As shown in FIG. 3 , the style adapting portion 340 includes a styleadapter 308, which applies the style obtained from the style parsingportion 320 into the chart 310 having a predefined style. The predefinedstyle of the chart 310 is modified into the style extracted from thereference image 302 to obtain the output chart 312. The output chart 312can be shown on a display, such that the user can operate the style ofthe output chart 312 to further modify or edit the style of the outputchart 312. The user can trim or tune the output chart 312 to improve thedisplay effect of the output chart 312.

FIG. 4 illustrates a schematic diagram of a decoder 400 in accordancewith some implementations of the present disclosure. The decoder 400 canbe applied into any of the decoders 306-1 to 306-N shown in FIG. 3 .However, it should be understood that the decoders 306-1 to 306-N shownin FIG. 3 also can be implemented by any other suitable models.

The decoder 400 receives, from the encoder, a representation 406 of thereference image, which representation is provided to a recurrent neuralnetwork 408 together with a vector representation 406 of a start tag404. The recurrent neural network 408 is a Long Short-Term Memory (LSTM)in this example. However, it should also be understood that any othersuitable networks can also be employed as substitution, such as GatedRecurrent Unit (GRU) and the like. The recurrent neural network 408outputs a first color 410 and provides a representation 412 of the firstcolor 410 and a representation 406 of the reference image together tothe recurrent neural network 408 for next iteration to obtain a secondcolor 414. A representation of the second color 414 and therepresentation 406 of the reference image are provided to the recurrentneural network 408 for next iteration, so as to obtain an end tag 418.An output 420 of a sequence including these colors is provided to asubsequent processing module for further processing.

FIG. 5 illustrates a flowchart of a method 500 for style transfer inaccordance with some implementations of the present disclosure. Forexample, the method 500 can be implemented by the computing device 100and also can be implemented in the example architecture and examplemodels demonstrated in FIGS. 2-4 .

At 502, a target object having a first style is obtained. The style ofthe target object is editable. For example, the target object caninclude at least one of chart and table.

At 504, a reference image including a reference object is obtained. Forexample, the reference object can include a chart and/or a table. Thereference object and the target object can have same or different type.For example, the reference object can be a bar chart while the targetobject can be a bar chart or a pie chart.

At 506, a second style of the reference object is obtained and thesecond style of the reference object is extracted from the referenceimage. In some implementations, the second style of the reference objectcan be extracted through the predefined rule.

In some implementations, the second style of the reference object can beextracted from the reference image via a neural network. For example,the reference image is converted, via the encoder, into a representationof the reference image and the representation of the reference image isconverted, via the decoder, into the style of the reference image. Forexample, the representation of the reference image is converted into aplurality of elements of the style via a plurality of decoders,respectively.

At 508, the second style is applied to the target object. For example,the second style can differ from the first style. The style represents acombination of multiple various elements. If one element in the secondstyle differs from the first style, the two styles are different. Inthis way, the first style is modified into the second style. In someimplementations, a target object having the second style is displayed.In response to receiving an editing operation on the target objecthaving the second style, the second style of the target object can bemodified. In this case, the user can further modify the style of thetarget object. Alternatively, in some cases, the second style may be thesame as the first style. Thus, when the second style is applied to thetarget object, the style of the target object does not change.

The solution of transferring the style in the reference image to theeditable object has been described above with reference to FIGS. 2-5 .In some implementations, the style of one editable object can betransferred to another editable object. FIG. 6 illustrates a flowchartof a method 600 for transferring a style of an editable object toanother editable object in accordance with some implementations of thepresent disclosure. The method 600 can be implemented by the computingdevice 100.

At 602, an editable object is obtained. The editable object may beassociated with a data set. For example, an editable object can begenerated based on the associated data, or an editable object can becopied from an editable object generated by another tool. The editableobject can be a chart for visualizing the data set or the tableincluding the data set. The editable object also can be the chart drawnbased on the data set, e.g., a bar chart. For the sake of convenience,the editable object is hereinafter referred to as the target editableobject and the corresponding data set is referred to as the target dataset.

At 604, one or more predefined editable objects whose similarity withthe target editable object is below a predefined threshold aredetermined from a plurality of predefined editable objects. Thepredefined editable objects have respective styles, which can be thestyles matching the data at a higher aesthetic degree. The similaritycan be measured in various suitable ways. For example, the similaritybetween two data can be measured by size of data amount, the number ofrows, the number of columns and size of the data value etc.

Furthermore, semantic information associated with the target editableobject (e.g., chart) also can be considered. For example, the similaritybetween the target editable object and the predefined editable objectcan be determined based on the text content in the chart. For example,if the title of the chart contains “percentage,” the chart is moresuitable to be displayed in the form of a pie chart and the chart ismore similar to a pie chart. In this way, the recommended style maydiffer from the original type of the target editable object. In anotherexample, the similarity in subject matter of the charts also can beconsidered. For example, the subject matter of the input chart can beobtained or derived based on the title of the input chart and tags ofrows or columns of the data, and the subject matter of the input chartis compared to the similar subject matter of the predefined charts.

In some implementations, a plurality of predefined editable objects canbe associated with a plurality of various categories, such as sciencecategory, finance category and the like. In such case, one or more datasets whose similarity with the target data set is below a predefinedthreshold can be respectively determined from the plurality ofcategories. Thus, styles in various categories can be recommended to theusers.

At 606, the one or more predefined editable objects are displayed foruser selection. Alternatively or additionally, the style correspondingto the data set with the highest similarity can be directly applied intothe target editable object. Such a style can be automatically displayedafter obtaining the editable object. Alternatively, the style can alsobe displayed after the user clicks a certain button or interfaceelement.

At 608, in response to receiving a selection of one of the one or morepredefined editable objects, the style of the editable object is appliedto the target editable object.

In this way, some better styles can be conveniently recommended to theuser for them to choose, thereby enhancing the convenient level of thestyle transfer.

Some example implementations of the present disclosure are listed below.

In a first aspect, there is provided a computer-implemented method. Themethod comprises obtaining a target object having a first style, thestyle of the target object being editable; obtaining a reference imagecomprising a reference object; obtaining a second style of the referenceobject, the second style of the reference object being extracted fromthe reference image; and applying the second style to the target object.

In some implementations, the second style of the reference object isextracted from the reference image by a neural network.

In some implementations, the reference image is converted to arepresentation of the reference image by an encoder, and wherein therepresentation of the reference image is converted to the second styleof the reference object by a decoder.

In some implementations, the representation of the reference image isconverted to a plurality of elements of the second style by a pluralityof decoders, respectively.

In some implementations, the second style of the reference object isextracted by a predefined rule.

In some implementations, the reference object and the target object eachinclude at least one of chart and table.

In some implementations, the method further comprises displaying thetarget object having the second style; and in response to receiving anediting operation on the displayed target object having the secondstyle, modifying the second style of the target object.

In a second aspect, there is provided a device comprising: a processingunit; and a memory coupled to the processing unit and includinginstructions stored thereon, the instructions, when executed by theprocessing unit, causing the device to perform acts comprising:obtaining a target object having a first style, the style of the targetobject being editable; obtaining a reference image comprising areference object; obtaining a second style of the reference object, thesecond style of the reference object being extracted from the referenceimage; and applying the second style to the target object.

In some implementations, the second style of the reference object isextracted from the reference image by a neural network.

In some implementations, the reference image is converted to arepresentation of the reference image by an encoder, and wherein therepresentation of the reference image is converted to the second styleof the reference object by a decoder.

In some implementations, the representation of the reference image isconverted to a plurality of elements of the second style by a pluralityof decoders, respectively.

In some implementations, the second style of the reference object isextracted by a predefined rule.

In some implementations, the reference object and the target object eachinclude at least one of chart and table.

In some implementations, the acts further comprise: displaying thetarget object having the second style; and in response to receiving anediting operation on the displayed target object having the secondstyle, modifying the second style of the target object.

In a third aspect, the present disclosure provides a computer programproduct tangibly stored in a non-transitory computer storage medium andincluding computer-executable instructions, the computer-executableinstructions, when executed by a device, causing the device to performthe method in the first aspect of the present disclosure.

In a fourth aspect, the present disclosure provides a computer-readablestorage medium stored thereon with computer-executable instructions, thecomputer-executable instructions, when executed by a device, causing thedevice to perform the method in the first aspect of the presentdisclosure.

The functionality described herein can be performed, at least in part,by one or more hardware logic components. For example, and withoutlimitation, illustrative types of hardware logic components that can beused include Field-Programmable Gate Arrays (FPGAs),Application-specific Integrated Circuits (ASICs), Application-specificStandard Products (ASSPs), System-on-a-chip systems (SOCs), ComplexProgrammable Logic Devices (CPLDs), and the like.

Program code for carrying out methods of the present disclosure may bewritten in any combination of one or more programming languages. Theseprogram codes may be provided to a processor or controller of a generalpurpose computer, special purpose computer, or other programmable dataprocessing apparatus, such that the program codes, when executed by theprocessor or controller, cause the functions/operations specified in theflowcharts and/or block diagrams to be implemented. The program code mayexecute entirely on a machine, partly on the machine, as a stand-alonesoftware package, partly on the machine and partly on a remote machineor entirely on the remote machine or server.

In the context of this disclosure, a machine readable medium may be anytangible medium that may contain, or store a program for use by or inconnection with an instruction execution system, apparatus, or device.The machine readable medium may be a machine readable signal medium or amachine readable storage medium. A machine readable medium may includebut not limited to an electronic, magnetic, optical, electromagnetic,infrared, or semiconductor system, apparatus, or device, or any suitablecombination of the foregoing. More specific examples of the machinereadable storage medium would include an electrical connection havingone or more wires, a portable computer diskette, a hard disk, a randomaccess memory (RAM), a read-only memory (ROM), an erasable programmableread-only memory (EPROM or Flash memory), an optical fiber, a portablecompact disc read-only memory (CD-ROM), an optical storage device, amagnetic storage device, or any suitable combination of the foregoing.

Further, although operations are depicted in a particular order, itshould be understood that the operations are required to be executed inthe shown particular order or in a sequential order, or all shownoperations are required to be executed to achieve the expected results.In certain circumstances, multitasking and parallel processing may beadvantageous. Likewise, while several specific implementation detailsare contained in the above discussions, these should not be construed aslimitations on the scope of the subject matter described herein. Certainfeatures that are described in the context of separate implementationsmay also be implemented in combination in a single implementation.Conversely, various features that are described in the context of asingle implementation may also be implemented in multipleimplementations separately or in any suitable sub-combination.

Although the subject matter has been described in language specific tostructural features and/or methodological acts, it is to be understoodthat the subject matter specified in the appended claims is notnecessarily limited to the specific features or acts described above.Rather, the specific features and acts described above are disclosed asexample forms of implementing the claims.

The invention claimed is:
 1. A computer-implemented method comprising:obtaining a target object having a first style, the first style of thetarget object being editable, wherein the target object includes avisual representation of a data element; obtaining a reference imagecomprising a reference object; obtaining a second style of the referenceobject, the second style of the reference object being extracted fromthe reference image by a neural network; determining that the secondstyle is applicable to the visual representation of the data elementbased on a category associated with the visual representation; modifyingthe first style using the second style; and reapplying the first styleto the target object.
 2. The method of claim 1, wherein the referenceimage is converted to a representation of the reference image by anencoder, and wherein the representation of the reference image isconverted to the second style of the reference object by a decoder. 3.The method of claim 2, wherein the representation of the reference imageis converted to a plurality of elements of the second style by aplurality of decoders, respectively.
 4. The method of claim 1, whereinthe second style of the reference object is extracted by a predefinedrule.
 5. The method of claim 1, wherein the reference object and thetarget object each include at least one of chart and table.
 6. Themethod of claim 1, further comprising: displaying the target objecthaving the second style; and in response to receiving an editingoperation on the displayed target object having the second style,modifying the second style of the target object.
 7. A device comprising:a processing unit; and a memory coupled to the processing unit andincluding instructions stored thereon, the instructions, when executedby the processing unit, causing the device to perform acts comprising:obtaining a target object having a first style, the first style of thetarget object being editable, wherein the target object includes avisual representation of a data element; obtaining a reference imagecomprising a reference object; obtaining a second style of the referenceobject, the second style of the reference object being extracted fromthe reference image, by a neural network; determining that the secondstyle is applicable to the visual representation of the data elementbased on a category associated with the visual representation; modifyingthe first style using the second style; and reapplying the first styleto the target object.
 8. The device of claim 7, wherein the referenceimage is converted to a representation of the reference image by anencoder, and wherein the representation of the reference image isconverted to the second style of the reference object by a decoder. 9.The device of claim 8, wherein the representation of the reference imageis converted to a plurality of elements of the second style by aplurality of decoders, respectively.
 10. The device of claim 7, whereinthe second style of the reference object is extracted by a predefinedrule.
 11. The device of claim 7, wherein the reference object and thetarget object each include at least one of chart and table.
 12. Thedevice of claim 7, wherein the acts further comprise: displaying thetarget object having the second style; and in response to receiving anediting operation on the displayed target object having the secondstyle, modifying the second style of the target object.
 13. A computerprogram product being stored on a non-transitory computer storage mediumand comprising machine-executable instructions, the machine-executableinstructions, when executed by a device, causing the device to performacts comprising: obtaining a target object having a first style, thefirst style the target object being editable, wherein the target objectincludes a visual representation of a data element; obtaining areference image comprising a reference object; obtaining a second styleof the reference object, the second style of the reference object beingextracted from the reference image by a neural network; determining thatthe second style is applicable to the visual representation of the dataelement based on a category associated with the visual representation;modifying the first style using the second style, and reapplying thefirst style to the target object.
 14. The computer program product ofclaim 13, wherein the reference image is converted to a representationof the reference image by an encoder, and wherein the representation ofthe reference image is converted to the second style of the referenceobject by a decoder.
 15. The computer program product of claim 14,wherein the representation of the reference image is converted to aplurality of elements of the second style by a plurality of decoders,respectively.
 16. The computer program product of claim 13, wherein thereference object and the target object each include at least one ofchart and table.
 17. The computer program product of claim 13, whereinthe second style of the reference object is extracted by a predefinedrule.
 18. The computer program product of claim 13, wherein the actsfurther comprise: displaying the target object having the second style;and in response to receiving an editing operation on the displayedtarget object having the second style, modifying the second style of thetarget object.